<template>
  <!-- 版本控制 二维码展示 -->
  <div>
    <puplic-modal
      width="500px"
      :publicVisible="publicVisible"
      modalStyle="addEditSupportModal"
      @cancel="publicVisible = false"
      :title="title"
    >
      <div slot="content">
        <div class="qr-img">
          <!-- <img src="@/assets/imgs/apkqr.png" alt="" /> -->
          <vue-qr :text="urlText" :size="300"></vue-qr>
        </div>
      </div>
      <div slot="footer"></div>
    </puplic-modal>
  </div>
</template>
<script>
import puplicModal from '@/components/publicModal'
import vueQr from 'vue-qr'

export default {
  components: { puplicModal, vueQr },
  name: 'apkQrCode',
  props: {
    title: {
      type: String,
      default: '',
    },
    urlText: {
      type: String,
      default: '',
    },
  },
  data() {
    return {
      publicVisible: false,
    }
  },
  methods: {
    show() {
      this.publicVisible = true
    },
  },
}
</script>
<style scoped lang="less">
.qr-img {
  margin: 0 auto;
  padding: 25px 0;
  width: 300px;

  img {
    width: 300px;
    height: 300px;
  }
}
</style>
